FlashEEPROM component emulate EEPROM

For general Flowcode discussion that does not belong in the other sections.
seokgi
Posts: 165
http://meble-kuchenne.info.pl
Joined: Thu Dec 03, 2020 1:43 pm
Has thanked: 5 times
Been thanked: 6 times

FlashEEPROM component emulate EEPROM

Post by seokgi »

Hello?
EEPROM was not included due to design mistakes. After searching the documentation, I found that there is a way to emulate a flash rom and use it like an EEPROM. Does FC9 also have a feature? Is it the FlashEEPROM component? Can you give a function description and example of FlashEEPROM?

Thank you.

medelec35
Matrix Staff
Posts: 1432
Joined: Wed Dec 02, 2020 11:07 pm
Has thanked: 506 times
Been thanked: 468 times

Re: FlashEEPROM component emulate EEPROM

Post by medelec35 »

Hello.
What target device have you got as the microcontroller has to have onboard flash program memory.
Have a look at your configuration settings and check if there is a SAF Enable option as that will have to be enabled.
If there is not then the microcontroller does not have Flash EEPROM capabilities.
I have not used the FlashEEPROM component with the 16F15324 I had, as it was not created then.
I used the normal EEPROM and that worked well.
Martin

seokgi
Posts: 165
Joined: Thu Dec 03, 2020 1:43 pm
Has thanked: 5 times
Been thanked: 6 times

Re: FlashEEPROM component emulate EEPROM

Post by seokgi »

It is a PIC24FJ512GA606.

Thank you.

BenR
Matrix Staff
Posts: 1707
Joined: Mon Dec 07, 2020 10:06 am
Has thanked: 435 times
Been thanked: 598 times

Re: FlashEEPROM component emulate EEPROM

Post by BenR »

Hello,

Yes the Flash EEPROM is the component you need. The properties for the component should allow you to choose a page in flash memory to assign to store the data.

There are then two functions read and write which allows you to read and write a 16-bit value from a 0 indexed location.

If you are having problems then let us know and I'll investigate and make an example to go on the wiki.

seokgi
Posts: 165
Joined: Thu Dec 03, 2020 1:43 pm
Has thanked: 5 times
Been thanked: 6 times

Re: FlashEEPROM component emulate EEPROM

Post by seokgi »

I did several tests. But that doesn't work. When the power is reset, the memory is also cleared.

The Initialize property is not visible.

can you send me an example?

BenR
Matrix Staff
Posts: 1707
Joined: Mon Dec 07, 2020 10:06 am
Has thanked: 435 times
Been thanked: 598 times

Re: FlashEEPROM component emulate EEPROM

Post by BenR »

Hello,

Please can you send us your project or a cut down version of so we can investigate how you're using the component. Ill also have a look at the datasheet for the PIC24FJ512GA606 and make sure our component is setup correctly for use with this.

seokgi
Posts: 165
Joined: Thu Dec 03, 2020 1:43 pm
Has thanked: 5 times
Been thanked: 6 times

Re: FlashEEPROM component emulate EEPROM

Post by seokgi »

Thank you.
I post my project here.
It's a bit complicated. Take a look at the E2PROM user macro section here. And in the Timer All part, I also want to know how to use the timer efficiently.
In the MODBUS user macro part, RS485 mode in BUS mode also does not work well. RS232 mode works fine.

Thank you for your attention.
Attachments
Auto_Lifting_Lamp_CTL_221129_ 01.fcfx
(233.81 KiB) Downloaded 35 times

BenR
Matrix Staff
Posts: 1707
Joined: Mon Dec 07, 2020 10:06 am
Has thanked: 435 times
Been thanked: 598 times

Re: FlashEEPROM component emulate EEPROM

Post by BenR »

Hello,

In your program you seem to write to locations 0, 1 and then on initialise you read from locations 1, 2.

For the Modbus component, maybe try adjusting the Reply delay property. Maybe try a value of 100 or 200 and hopefully this might make a difference.

seokgi
Posts: 165
Joined: Thu Dec 03, 2020 1:43 pm
Has thanked: 5 times
Been thanked: 6 times

Re: FlashEEPROM component emulate EEPROM

Post by seokgi »

Still not working.
I am uploading my modified project.
Can you write a simple example project for me?

And the FlashEEPROM component does not have the Initialise property in the attached picture. Will this work without it?

https://www.flowcode.co.uk/wiki/index.p ... _component
Attachments
Initialise.jpg
Initialise.jpg (70.83 KiB) Viewed 1265 times
Auto_Lifting_Lamp_CTL_221201_ post.fcfx
(79.48 KiB) Downloaded 35 times

seokgi
Posts: 165
Joined: Thu Dec 03, 2020 1:43 pm
Has thanked: 5 times
Been thanked: 6 times

Re: FlashEEPROM component emulate EEPROM

Post by seokgi »

Hello.
Just request every time.

when will it be resolved?

Thank you.

Post Reply