Setfileindex0 and 1
Moderator: Benj
- mikn
- Posts: 209
- Joined: Mon Mar 03, 2014 10:11 pm
- Has thanked: 54 times
- Been thanked: 41 times
- Contact:
Setfileindex0 and 1
I am trying to read string from file1 and save it to file2 using SetFileIndex(0) and (1)
But I get read strings from File2 and added to same File2 at the end.
What may be wrong?
Code screenshot included.
But I get read strings from File2 and added to same File2 at the end.
What may be wrong?
Code screenshot included.
- Attachments
-
- sc-file12.GIF (7.09 KiB) Viewed 7609 times
FC 6.1.3.2 (18.02.2016)
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: Setfileindex0 and 1
Hello,
That looks correct to me. I'll have a go here and see if I can find out what the problem is.
Thinking about it you will probably need to call the ReadFileSector function each time after you set the file index. Otherwise the shared sector buffer will likely be getting corrupted.
That looks correct to me. I'll have a go here and see if I can find out what the problem is.
Thinking about it you will probably need to call the ReadFileSector function each time after you set the file index. Otherwise the shared sector buffer will likely be getting corrupted.
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: Setfileindex0 and 1
Ok thanks, I'll set this up tomorrow morning and see if I can get it to work correctly.
Is the problem your seeing on hardware or using the simulation or both?
Is the problem your seeing on hardware or using the simulation or both?
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
- mikn
- Posts: 209
- Joined: Mon Mar 03, 2014 10:11 pm
- Has thanked: 54 times
- Been thanked: 41 times
- Contact:
Re: Setfileindex0 and 1
It's on hardware.
upd:
seems like something is wrong with switching at SetFileIndex. Even when I set wrong index (file1 is 0 and file2 is 1, but i set to 2) it was reading and writting from/to the last opened file. Same confirmed when I've changed the order - opened file2 and then file1. It was reading and writting to file1 only.
upd:
seems like something is wrong with switching at SetFileIndex. Even when I set wrong index (file1 is 0 and file2 is 1, but i set to 2) it was reading and writting from/to the last opened file. Same confirmed when I've changed the order - opened file2 and then file1. It was reading and writting to file1 only.
FC 6.1.3.2 (18.02.2016)
- mikn
- Posts: 209
- Joined: Mon Mar 03, 2014 10:11 pm
- Has thanked: 54 times
- Been thanked: 41 times
- Contact:
Re: Setfileindex0 and 1
Wed Oct 01, 2014 1:09 pm
Benj wrote:Ok thanks, I'll set this up tomorrow morning
FC 6.1.3.2 (18.02.2016)
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: Setfileindex0 and 1
Hello,
Right finally it's been quiet in the office and I have been able to spend some time looking into this for you.
I have only tried a single 512 byte sector copy of the test.txt file into test2.txt but it seems to be working correctly for me.
Had a couple of issues but then I formatted the card I was using and everything now seems to be working correctly.
Let me know how you get on.
Right finally it's been quiet in the office and I have been able to spend some time looking into this for you.
I have only tried a single 512 byte sector copy of the test.txt file into test2.txt but it seems to be working correctly for me.
Had a couple of issues but then I formatted the card I was using and everything now seems to be working correctly.
Let me know how you get on.
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
- mikn
- Posts: 209
- Joined: Mon Mar 03, 2014 10:11 pm
- Has thanked: 54 times
- Been thanked: 41 times
- Contact:
Re: Setfileindex0 and 1
This code:
file1: empty
file2: to file 1to file 2
This code: gives this result:
file1: testfrom1
file2: \mB`kYЌkph^\b[v~YDcztGlh†sKi2ДўPsj€{яя1D3е:5K™bЂ4rаv‘`“…ѓrЊ[|2sXѕ„W_f]uqflaЌZ‚o[Њej›i•urk][6ѓyfNђnu7ѓhqXo=:Тія4: чpTGxE>5?2яІ©~zУ~hыRСi_qdWwscforПHm~WS][xOmtq=k|bgv`jm„OpZV€wUN—jf_>mt§SOGеRSя3ЧЕяl5‚1QK5ђeѓя\бv±@ЎupX“d‹gVZ]pok{CЉntK{ete‰c\zSq‰5ЋµS<surxkfX{P6tlП‹›Hђ7БЉ4|Ь…§з4922ўќ4um27Tt®‘oфE™fsw}]YsTe~]^ciYcunntkbTYYђoofџbLSPwajt4‹yiYS–hВеFUгJBMяю‰Ґ6фЎG89?I/‘RЂ~Њv2ЅhЊzny‡|jUUЃ\qnЗIЂtw[wF‡Д_љaen]kkdU~S]c|kaq^ckaRk5gM…lЋд;S6‹›‹ 32>ђ02цiЏS†V€1?•†k\ySjzv|N8’ep‚bi@`Џ8Y„Ђi‰J™P
(512 bytes of trash)
ps:
gives this result:file1: empty
file2: to file 1to file 2
This code: gives this result:
file1: testfrom1
file2: \mB`kYЌkph^\b[v~YDcztGlh†sKi2ДўPsj€{яя1D3е:5K™bЂ4rаv‘`“…ѓrЊ[|2sXѕ„W_f]uqflaЌZ‚o[Њej›i•urk][6ѓyfNђnu7ѓhqXo=:Тія4: чpTGxE>5?2яІ©~zУ~hыRСi_qdWwscforПHm~WS][xOmtq=k|bgv`jm„OpZV€wUN—jf_>mt§SOGеRSя3ЧЕяl5‚1QK5ђeѓя\бv±@ЎupX“d‹gVZ]pok{CЉntK{ete‰c\zSq‰5ЋµS<surxkfX{P6tlП‹›Hђ7БЉ4|Ь…§з4922ўќ4um27Tt®‘oфE™fsw}]YsTe~]^ciYcunntkbTYYђoofџbLSPwajt4‹yiYS–hВеFUгJBMяю‰Ґ6фЎG89?I/‘RЂ~Њv2ЅhЊzny‡|jUUЃ\qnЗIЂtw[wF‡Д_љaen]kkdU~S]c|kaq^ckaRk5gM…lЋд;S6‹›‹ 32>ђ02цiЏS†V€1?•†k\ySjzv|N8’ep‚bi@`Џ8Y„Ђi‰J™P
(512 bytes of trash)
ps:
I really respect your work performance but each time I wonder why you do all the job alone? You do the code, you answer questions and so on. I wonder why you don't involve some more people into the support process?Right finally it's been quiet in the office and I have been able to spend some time looking into this for you.
FC 6.1.3.2 (18.02.2016)
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: Setfileindex0 and 1
We are a fairly small company with a small dev team which is why we rely on the VC's interacting on the forums and helping with support. I would love to have more help but unless we sell more copies of Flowcode to justify increasing the size of the team I don't see it happening. Also you can't just hire anyone they have to be passionate and skilled otherwise it's just more of a drain on me .I wonder why you don't involve some more people into the support process?
The last three or four employee's to be hired at Matrix have all been sales / marketing type people. Even the head of development is now pretty much completely focused on sales and marketing! Maybe the next employment will be for a new dev team member but I think this is doubtful. This is not all bad news as we are now at least managing to come up with ways of selling the new and exciting stuff rather then just sitting on it for a few months and then concluding it has been a failure. However the new ECIO literally has been ready to ship for a year and it's literally taken this long just for me to justify it's existence to my non technical managers. They want something to compete with Arduino but the ECIO doesn't feel right to them?!
Anyway rant over and I'll look into the problem a bit deeper and see if I can find a solution for you.
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
- mikn
- Posts: 209
- Joined: Mon Mar 03, 2014 10:11 pm
- Has thanked: 54 times
- Been thanked: 41 times
- Contact:
Re: Setfileindex0 and 1
Thanks for the detailed reply, Benj. It's really appreciated because in bigger software companies it's hard to talk to real coders and not just stupid support girls who read internal FAQ and quote it to the client.
With FC I have found a new field where I can realize my professional skills skipping the long way of reading tons of books. I see you produce boards too, but I think the big perspective is to add as more components as you can for each of known devices in the market. With ready components people can construct ready to work devices like LEGO constructor.
As for me I have a good guys who work for me and create hardware parts. I do the code and logic. If you could add more wireless devices, specific sensors and so on, also optimize and speed up the FAT component, ADC component and all other realtime parts, the value of FC will be... invaluable
The most annoying things now are bugs and time how long it takes to fix them. That's why I remind about some problems often. I've bought pro version and do commercial product now. And it has some deadline time. I can't go forward sometimes because I stuck on the place and, for example, can't create two files (as with Setfileindex issue).
Think about payable support. 1-2 hours of private chat sometimes is enough to find the problem and move forward and clients won't wait too much if they need support right now. That's the good stimulus to new coder also.
With FC I have found a new field where I can realize my professional skills skipping the long way of reading tons of books. I see you produce boards too, but I think the big perspective is to add as more components as you can for each of known devices in the market. With ready components people can construct ready to work devices like LEGO constructor.
As for me I have a good guys who work for me and create hardware parts. I do the code and logic. If you could add more wireless devices, specific sensors and so on, also optimize and speed up the FAT component, ADC component and all other realtime parts, the value of FC will be... invaluable
The most annoying things now are bugs and time how long it takes to fix them. That's why I remind about some problems often. I've bought pro version and do commercial product now. And it has some deadline time. I can't go forward sometimes because I stuck on the place and, for example, can't create two files (as with Setfileindex issue).
Think about payable support. 1-2 hours of private chat sometimes is enough to find the problem and move forward and clients won't wait too much if they need support right now. That's the good stimulus to new coder also.
FC 6.1.3.2 (18.02.2016)
-
- Valued Contributor
- Posts: 2045
- Joined: Wed Aug 27, 2008 10:31 pm
- Location: Netherlands
- Has thanked: 553 times
- Been thanked: 1081 times
- Contact:
Re: Setfileindex0 and 1
Matrix offers a service you might want to look into. Quoting from the April edition of the Matrix newsletter:
Professional Services
Over the last few years the number of industrial companies who are now using Flowcode to develop commercial products has risen considerably. We
have been contacted by some companies who need a greater level of support in their development departments. With this in mind we are pleased to
announce the launch of Professional services to meet the growing demand for more tailored support from companies using Flowcode. We now offer three
separate services:
Rapid customer Support provides you with fast response to your technical queries within targeted guidelines. On submission of an issue we will
take full ownership of your request, keep you up to date with the status of the problem, will prioritise its remedy, and will give you the
assistance you need to rapidly solve your issues, allowing you to keep your projects on track.
Extended Services allows customers the ability to subcontract specific pieces of work within the product development cycle to the appropriate
experts within the Matrix development team. With Extended Services, customers purchase an agreed amount of hours and are able to call off those
hours on a variety of projects under the terms of a service level agreement.
The Accelerator package is designed for new customers to help them get up and running with Flowcode 6 within the shortest possible time. Matrix
staff will take on the work of installing Flowcode software to our best practice recommendation, will train your staff in using Flowcode with a
dedicated course to bring you up to intermediate levels of design capability in just 2 days.
If you’re interested in finding out more about these services, please contact us
“Integrity is doing the right thing, even when no one is watching.”
― C.S. Lewis
― C.S. Lewis
- mikn
- Posts: 209
- Joined: Mon Mar 03, 2014 10:11 pm
- Has thanked: 54 times
- Been thanked: 41 times
- Contact:
Re: Setfileindex0 and 1
That's what I did with my last messageIf you’re interested in finding out more about these services, please contact us
FC 6.1.3.2 (18.02.2016)
- mikn
- Posts: 209
- Joined: Mon Mar 03, 2014 10:11 pm
- Has thanked: 54 times
- Been thanked: 41 times
- Contact:
Re: Setfileindex0 and 1
I am dumb.
solved by
FAT -> max_concurrent_files -> set to 2, instead of 1.
damn. I thought that 1 means +1 concurrent file to already opened.
solved by
FAT -> max_concurrent_files -> set to 2, instead of 1.
damn. I thought that 1 means +1 concurrent file to already opened.
FC 6.1.3.2 (18.02.2016)