FRAM is connected with I2C.
Why there is not anybody to help me or give me any solution?
It is very important for me to do In Application Programming with FRAM.
Thanks for attention...
1-how can i create new bootloadable image? then i send image to gsm for write on FRAM.
- As per my understanding, in the design, PSoC 5LP connects FRAM with I2C, and the PSoC 5LP connects GSM with UART, right?
It's just like: FRAM <--I2C--> PSoC5LP <--UART--> GSM. Is that right?
- And now you'd like to update bootloadable in PSoC 5LP through GMS? If yes, GSM should plays as a 'bootloader host', GSM should send bootload command and new image to PSoC 5LP to finish its bootload..
- Then...What does it mean about "then i send image to gsm for write on FRAM."? Sorry I've not understood yet....
2- what is the meta data configure true on FRAM?(please explain me to set byte by byte of FRAM)
- As I knew, meta data, is a section of bootloadable of PSoC 5LP, why does it store in the FRAM? If the image is stored in FRAM, as the image prepared to update PSoC 5LP bootloadable code, what is the role of GSM (As you said, you'd like to update PSoC 5LP in working with GSM)? In the system: FRAM <--I2C--> PSoC5LP <--UART--> GSM, new image is stored in FRAM. As a bootloader host, GSM doesn't connect with the FRAM who has the new image, how does GSM send the image to PSoC 5LP? If you'd like to send the image stored in FRAM to PSoC 5LP to replace the old image in PSoC 5LP. In this case, I think Bootloader/bootloadable is meaningless....
- Another understanding of your application is, the design is like: PSoC5LP <--UART--> GSM <--I2C--> FRAM. Then you can use GSM as a bootloader host, send bootloader command, read and send image stored in the FRAM to PSoC 5LP for bootloading.
The format of meta data is documented in https://www.cypress.com/file/140346/download
If you want to store meta data in the FRAM, you can store it in FRAM with ANY format you want, as long as you can read it back and store it in PSoC 5LP Flash as the correct format described in above document when update image in PSoC 5LP...So again, come back to previous confusion point, what is the system like and what is the relationship of them?
3- what is the bootloader configured should be to read new bootloadble from FRAM and do In Apllication Programming ?
It is very important for me to do FOTA with GSM, please help me...
- According to this question....The system can be confirmed: PSoC5LP <--UART--> GSM <--I2C--> FRAM?
So, it could be easily understood, you may use the GSM as UART bootloader host, read image stored in FRAM and send the image to PSoC 5LP through UART. So, PSoC UART bootloader Code Example is FYI.
You can refer its Bootloader host example in it for GSM:
- About how to read and write I2C FRAM, refer:
You may port the code to GSM.
Sorry for that, when reading your previous two questions, I've not understood the system design. So I hope the comments for your 3rd question may help something. Good luck!
Thanks dear RyanZ_36 for reply...
1-I want to get new bootloadable.hex or .cyacd file with gsm and then write it on EEPROM with psoc5, but it is not important and it is not my issue.I want to run bootloader on custom interface and i can using another way to write.So my question exactly is how i can configure bootloader in custom interface to read new bootloadable from external EEPROM and programming internal flash?
2- Thanks for explain meta data. You say correct i do not need to write meta data on external EEPROM.
3- I dont want to run GSM as UART bridge.because i fear to loss connection before programming finished so It has a very harmful for me.... In fact i need to write new program on external EEPROM first, then load bootloader to read and write new bootloadable from external EEPROM to internal flash of psoc5.
4- I am using PSoC 4 EEPROM Bootloader Example - Hackster.io and its worked well but its bootloader version is v1.2 and now i can not to modify my project on psoc5 as it because in PsocCreator v4.2 bootloader version is 1.6 and it has some different configuration in CyBtldrCommWrite() and CyBtldrCommRead() function. can you help me to modify project in psoc5 and say me where is my mistake?
I attached project below.Thank for attention...
I try to get code from BLE_Over_The_Air.cywrk.Archive01 sample code(exactly for CyBtldrREAD and CyBtldrWRITE API in bootloader).now i share it with u.it does not get app from external eeprom.please check it and tell me where is mistake?
bootload.zip 7.6 MB
Hi, I am developer on psoc microcontroller.
I created a device with some feature like GSM and RS485 and external FRAM with I2C and so on...
Its worked well and it work for controlling irrigation in agriculture smarter by getting some function from server on GSM and control monitoring some sensor like TEMP and HUMIDITY on farm. Its so long to describe all of that....
I am doing this project with psoc5 and using FreeRTOS. It is so good without any hangup or effective from noise or any other destructive situation.
Now i have an important question that is so useful for me to reach FOTA on my device.(to change firmware of device to new)
I using example from cypress BLE_OTA_External_Memory_Bootloader and i know how can i creat 128 byte od meta data and how write structure on external memory FRAM true to update firmware by bootloader program. below is structure of OTA in that sample:
Image Size in flash rows
Number of the first flash row
External memory page size
True(0x56) or False or Loaded(0x4C) App status
0x00000000 show disable mode
Sum all of .cyacd program data in each row,then 2complementation
Number of row in .cyacd
In this example is 0x74
show page of EEPROM (here is 64Kbyte)
Cause in my project i am using psoc5 and it has not struct like psoc4ble so i cant find how to change BLE_OTA_External_Memory_Bootloader to modified on psoc5.for example each row in psoc4ble is 128 byte but in psoc5 is 288 byte.
I try to build an easy sample code like LED blinking and adding Bootloadable on my project to create .cyacd file from project.It is build and i write on external memory like sample project.Calculate meta data by above structure in chart but i cant modified BLE_OTA_External_Memory_Bootloader to OTA true.
please tell me how can i do?
and if i need own bootloader program how can i create that to reach my purpose?
Plaese tell me how can i modified on psoc5lp?
thanks for attention...
I am waiting long time for response,Is there any solution to help me for running In Application Programming from external memory for psoc5? Or tell me how i can modify sample code psoc4ble to psoc5(because meta data and each line in flash of psoc5 has differenece from psoc4ble)
It is very important for me.please guid me soon.
thanks for attention...
For bootloader, it is writting app data into certain PSoC Flash address row by row.
In bootloader, row writing API could be used for the writing. you can refer PSoC 5 Flash writing examples (1 example is Flash_Example in PSoC Creator), read data from host and write the app data into certain memory. It supports any communication mode with host.
Thanks a lot dear Ruzhe_36 for your explain. I am run a bootloader program on luncher mode to read eeprom, then write bootloadable file(.cyacd) from external eeprom to internal falsh by CYFLASH.h function.
Its worked well and do everything that i want.
I upload my sample project here for everybody that have OTA problem like me...
but for more information i have two question:
1- What is config flash partition exactly?why write or not write config flash area has no difference in bootloadable working?
2-How i can store .cyacd in empty internal flash area? because CYFLASH.h has no any function for read flash row data. Can you help me?
thanks for attention...
Bootload.zip 5.7 MB