Jump to content

Search the Community

Showing results for tags 'flash'.

More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


  • News
    • Announcements
    • Suggestions
    • New users say Hi!
  • Spotlight!
    • Sponsor Spotlight
    • Sponsor Giveaways
  • Energia
    • Energia - MSP
    • Energia - TivaC/CC3XXX
    • Energia - C2000
    • Energia Libraries
  • MSP Technical Forums
    • General
    • Compilers and IDEs
    • Development Kits
    • Programmers and Debuggers
    • Code vault
    • Projects
    • Booster Packs
    • Energia
  • Tiva-C, Hercules, CCXXXX ARM Technical Forums
    • General
    • SensorTag
    • Tiva-C, Hercules, CC3XXX Launchpad Booster Packs
    • Code Vault
    • Projects
    • Compilers and IDEs
    • Development Kits and Custom Boards
  • Beagle ARM Cortex A8 Technical Forums
    • General
    • Code Snippets and Scripts
    • Cases, Capes and Plugin Boards
    • Projects
  • General Electronics Forum
    • General Electronics
    • Other Microcontrollers
  • Connect
    • Embedded Systems/Test Equipment Deals
    • Buy, Trade and Sell
    • The 43oh Store
    • Community Projects
    • Fireside Chat
  • C2000 Technical Forums
    • General
    • Development Kits
    • Code Vault
    • Projects
    • BoosterPacks


There are no results to display.

Find results in...

Find results that contain...

Date Created

  • Start


Last Updated

  • Start


Filter by number of...


  • Start



Website URL





Found 15 results

  1. Hi, I am not familiar with CCS and a novice in TI Launchpads. I have written an Energia code and would like to burn it into CC3220SF launchpad Flash memory so I could execute the code while disconnected from PC USB. I looked at e2e.ti.com/.../2495478, but did not work for me. Could you please guide me achieve this? Thanks, Sam
  2. Good morning (or good evening)! First of all, if these questions are stupid, don't spare my feelings. I know better than anyone that I'm still new at this and I have thick skin. I've had a great deal of success writing my own sketches with Energia. It's fun, simple-to-use, and easy to explain to others, but I have a few questions: 1) is Energia suitable for firmware in a small commercial product or is it intended more as a rapid prototyping framework, with "permanent" firmware written in CC7? 2) When working with a PCB using the CC3200MOD, how would I flash my Energia sketch onto the modules flash? 3) If I were to have a few hundred PCBs produced for a task at my day job, would each PCB (using the CC3200MOD) have to be individually flashed by hand or is there a way to have this done during the assembly process? For a small project like this, I don't feel that having a PCB designer work out a PCB trace antenna would be cost effective - plus my boss would want to avoid FCC issues at all costs - so the MOD version would clearly be better. I just don't know enough (yet) to know if the MOD version can be used in mass production, even on a small scale. Again, as I said, I've had SO much fun with Energia! I would like to thank Robert Wessels for making this experience possible. I feel like I could make every device and every toy that I've ever thought would be cool, by using Energia with the TI CC3200 platform. This is so cool!
  3. Hi all, I need to import/upload data to my MSP432P401R to call upon in future programs. Since I want this data to exist and be saved when my MSP432 is offline/powered-off, I decided that saving it to flash is the way to go. However, I don't know how to do this. Can anyone offer guidance or suggestions? Or does anyone have a better way of doing this? I'm using Energia v18.
  4. Hello guys i wrote a simple code with a intrerupt on button 2 on MSP430F5529 when i hit the button 2 int should save in flash but when i disconect my microcontroler the variable reset please help me. #include <Wire.h> #include "LiquidCrystal_I2C.h" #include "MspFlash.h" #define flash SEGMENT_D #define flash1 SEGMENT_C byte address = 0x27; // LCD I2C address int columns = 20; // number of columns on LCD int rows = 2; // number of rows on LCD LiquidCrystal_I2C lcd(address, columns, rows); int i1=20; int *pi1=&i1; int i2=0; int *pi2=&i2; int i11=30; int *pi11=&i11; int i22=0; int *pi22=&i22; void setup() { Serial.begin(9600); pinMode(GREEN_LED, OUTPUT); lcd.init(); pinMode(PUSH2, INPUT_PULLUP); attachInterrupt(PUSH2, blink1, FALLING); // Interrupt is fired whenever button is pressed } void loop() { i1=i1+1; i11=i11+1; digitalWrite(GREEN_LED,HIGH); delay(100); digitalWrite(GREEN_LED,LOW); delay(100); lcd.setCursor(0,0); lcd.print(i2); lcd.setCursor(0,1); lcd.print(i22); } void blink1() { Flash.erase(flash); Flash.write(flash,(unsigned char*) pi1,sizeof(int)); Flash.read(flash,(unsigned char*) pi2,sizeof(int)); Flash.erase(flash1); Flash.write(flash1,(unsigned char*) pi11,sizeof(int)); Flash.read(flash1,(unsigned char*) pi22,sizeof(int)); }
  5. Hello guys i'm working on an application where i need to save 2 float numbers in flash memory (i need them when the msp lose power) ,i have the hardware part done but i can't figure out the coding i'm very new to programing. I need to do something like this. int sensorPin = 23; int sensorValue = 0; float volt; // loop part sensorValue = analogRead(sensorPin); unsigned long currentMillis = millis(); timp=currentMillis/1000; if(currentMillis - previousMillis > interval) { previousMillis = currentMillis; volt=sensorValue; volt=(volt*3.3)/4096; volt=volt*8.51; putere1=volt*amp1; total_putere1=putere1+total_putere1; } media_puteri1=total_putere1/timp; energie1=media_puteri1*timp/3600; I need to save "energie1" to flash and whe my msp lose power the value stays on and then when i power it back my "energie1" value goes something like this energie1=(media_puteri1*timp/3600)+flash_value; PS: i read the ENERGIA flash write/read exemple but i don't understand how to save float values;
  6. Hello guys i have a project at my school were i need to make an energy metter with a msp430f5529 and a hardware part i did all the code myself and the hardware part (current metters,voltage divider etc), (i know is rudimental and ineffective) , the code and the montage works well and does everything i need it to do.Now my professor asked me to save "energie1" and "energie2" so when my microcontroler runs out of battery this 2 variables are saved , i read a lot of threds but i can't figure it out.Here is the code if it helps ( i can provide you with hardware montage if needed). #include <Wire.h> #include "LiquidCrystal_I2C.h" byte address = 0x27; // LCD I2C address int columns = 20; // number of columns on LCD int rows = 2; // number of rows on LCD LiquidCrystal_I2C lcd(address, columns, rows); long previousMillis = 0; long previousMillis1 = 0; int timp; int sensorPin = 23; int sensorValue = 0; float volt; byte newChar1[] = { B11111, B10001, B10001, B10001, B10001, B10001, B10001, B11111 }; byte newChar2[] = { B00000, B00000, B11100, B11100, B11100, B11100, B00000, B00000 }; byte newChar3[] = { B11111, B11111, B11111, B11111, B11111, B11111, B11111, B11111 }; int sensorPin1 = 24; int sensorValue1 = 0; float amp1; int sensorPin2 = 25; int sensorValue2 = 0; float amp2; float putere1; float total_putere1; float energie1; float media_puteri1; float putere2; float total_putere2; float energie2; float media_puteri2; long interval = 1000; long interval1=270; const int buttonPin = PUSH2; int buttonPushCounter = 0; int buttonState = 0; int lastButtonState = 0; void setup() { lcd.init(); pinMode(buttonPin, INPUT_PULLUP); lcd.createChar(0, newChar1); lcd.createChar(1, newChar2); lcd.createChar(2, newChar3); } void loop() { buttonState = digitalRead(buttonPin); sensorValue = analogRead(sensorPin); sensorValue1 = analogRead(sensorPin1); sensorValue2 = analogRead(sensorPin2); unsigned long currentMillis = millis(); unsigned long currentMillis1 = millis(); timp=currentMillis/1000; if(currentMillis - previousMillis > interval) { previousMillis = currentMillis; volt=sensorValue; volt=(volt*3.3)/4096; volt=volt*8.51; amp1=sensorValue1; amp1=(amp1*3.3)/4096; if(amp1<0.5) amp1=0; amp1=amp1/0.5; amp2=sensorValue2; amp2=(amp2*3.3)/4096; amp2=amp2/0.05; if(amp2<1.25) amp2=0; putere1=volt*amp1; putere2=volt*amp2; total_putere1=putere1+total_putere1; total_putere2=putere2+total_putere2;} if (buttonState == LOW) { lcd.backlight(); } else lcd.noBacklight(); if(currentMillis1 - previousMillis1 > interval1) { previousMillis1 = currentMillis1; if(buttonPushCounter==1){ lcd.clear(); lcd.setCursor(0,0); lcd.print("Battery Voltage"); lcd.setCursor(0,1); lcd.print(volt); lcd.print(" V");} if(buttonPushCounter==2){ lcd.clear(); lcd.setCursor(0,0); lcd.print("Solar Current"); lcd.setCursor(0,1); lcd.print(amp1); lcd.print(" A");} if(buttonPushCounter==3){ lcd.clear(); lcd.setCursor(0,0); lcd.print("Pump Current"); lcd.setCursor(0,1); lcd.print(amp2); lcd.print(" A");} if(buttonPushCounter==4){ lcd.clear(); lcd.setCursor(0,0); lcd.print("Solar Energy"); lcd.setCursor(0,1); lcd.print(energie1); lcd.print(" Wh");} if(buttonPushCounter==5){ lcd.clear(); lcd.setCursor(0,0); lcd.print("Pump Energy"); lcd.setCursor(0,1); lcd.print(energie2); lcd.print(" Wh");} if(buttonPushCounter==6){ lcd.clear(); if(volt>12.6){ lcd.clear(); lcd.setCursor(0,1); lcd.write(2); lcd.write(2); lcd.write(2); lcd.write(2); lcd.write(2); lcd.write(1); lcd.setCursor(0,0); lcd.print("State Of Charge"); lcd.setCursor(6,1); lcd.print("100"); lcd.print("%");} if(volt<12.45 && volt>12.21){ lcd.clear(); lcd.setCursor(0,1); lcd.write(2); lcd.write(2); lcd.write(2); lcd.write(2); lcd.write(0); lcd.write(1); lcd.setCursor(0,0); lcd.print("State Of Charge"); lcd.setCursor(6,1); lcd.print("80"); lcd.print("%");} if(volt<12.20 && volt>11.91){ lcd.clear(); lcd.setCursor(0,1); lcd.write(2); lcd.write(2); lcd.write(2); lcd.write(0); lcd.write(0); lcd.write(1); lcd.setCursor(0,0); lcd.print("State Of Charge"); lcd.setCursor(6,1); lcd.print("60"); lcd.print("%");} if(volt<11.90 && volt>11.60){ lcd.clear(); lcd.setCursor(0,1); lcd.write(2); lcd.write(2); lcd.write(0); lcd.write(0); lcd.write(0); lcd.write(1); lcd.setCursor(0,0); lcd.print("State Of Charge"); lcd.setCursor(6,1); lcd.print("40"); lcd.print("%");} if(volt<11.59){ lcd.clear(); lcd.setCursor(0,1); lcd.write(2); lcd.write(0); lcd.write(0); lcd.write(0); lcd.write(0); lcd.write(1); lcd.setCursor(0,0); lcd.print("State Of Charge"); lcd.setCursor(6,1); lcd.print("20"); lcd.print("%");}} if(buttonPushCounter>6) buttonPushCounter=1;} if (buttonState != lastButtonState) { if (buttonState == HIGH) { buttonPushCounter++;}} lastButtonState = buttonState; media_puteri1=total_putere1/timp; energie1=media_puteri1*timp/3600; media_puteri2=total_putere2/timp; energie2=media_puteri2*timp/3600; }
  7. Does anyone have any code examples, experience, or can point me to the right direction when it comes to reading/writing to the internal flash that comes with these boards in Energia? I'm wanting to store up to a maximum of a days worth of non-volatile 3x32 bit 5 minute samples (3,456 bytes), before sending as packets when the Rx is in range. Thanks in advance!
  8. Hi, I am currently working on a code in Energia that will allow me to upload and send a binary file wirelessly from a client site to the CC3200. So far, the code has successfully accomplished the following: -the board establishes a Wi-Fi network -commands from a laptop can interact with the board (the Energia Simple Wi-Fi Server example (LED ON/OFF) code was tested to ensure this was working) -a 9 byte binary file is sent through Wi-Fi to the board's volatile memory, saved from volatile memory into an on-baord flash memory file, and confirmed by sending it back to the laptop through a serial connection The code is eventually supposed to receive a larger binary file (we hope around 500 KB) that will represent points on a sinusoidal curve. This file will then be sent to the Audio Booster Pack board to play the audio file. I created a flash file which was opened, and written to through a buffer array containing the binary file contents. This method was successful for a 9 byte file, but I learned that a larger 500 KB file cannot be stored in a buffer array so easily. I think this is because of a lack of RAM space on the board. How can I implement a code in Energia in order save this larger binary file to the flash memory? Is the buffer array approach a good method? Latency isn't really an issue, as long as we can fit the whole file on the board, and then play it after. Thanks, any support is greatly appreciated!
  9. Hello! I am using Energia to program TM4C123GXL board. The program performs a primitive data acquisition with low frequency and stores it (together with timestamps) as an array in RAM. I would like to store data in EEPROM or, preferebly in FLASH. Micro-controller has 256kB flash. How can I save data there? There is flash API (flash.h and flash.c) in lm4f/driverlib/ though I am not sure even at which address range I can write/erase data? Can anybody point out to a working example? thanks for help!
  10. Hi, I'm currently developing a software for the MSP430F5510. It worked fine with my development PCB for months, but as soon as I tried it on another one, I got very strange issues. My software is writing text to a display with a built-in font, and I'd sometimes get missing pixels, or the text "dEbug" or "debuf" instead of "debug". I then simplified my code until I arrived at this: #include <msp430.h> #include <string.h> #include "driverlib/MSP430F5xx_6xx/ucs.h" static const uint16_t flash_data[] = { 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, }; static volatile uint16_t ram_data[] = { 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, }; void main(void) { volatile uint32_t cnt = 0; static const uint32_t mclk = 25000000; WDTCTL = WDTPW | WDTHOLD; UCS_clockSignalInit(UCS_FLLREF, UCS_REFOCLK_SELECT, UCS_CLOCK_DIVIDER_1); UCS_initFLLSettle(mclk/1000, mclk/32768); while (1) { if (memcmp(&flash_data, (void*)&ram_data, sizeof(flash_data)) != 0) { _op_code(0x4343); } cnt++; } } My code sometimes stops on the software breakpoint, so it seems sometimes the flash gets read incorrectly. Most of the times this happens very soon after the program starts (cnt <= 50), but sometimes it takes a lot longer (cnt = some millions). Then after the next reset it immediately happens again. Some observations I made so far: It does not seem to happen when the clock is 24MHz instead of 25MHz It does not seem to happen on 2 of 4 prints I tested When I use single values rather than arrays, it happens more seldom. If I use != instead of memcmp to compare them, it doesn't seem to happen (maybe it gets optimized away though?). Optimisation level doesn't seem to make a difference Inserting an ~1s delay before and after setting the clock doesn't make a difference It seems it's always an 1 bit read as 0, i.e. I can't reproduce it if the data is 0x00 instead of 0xFF CCSv5 project with the above minimal example: 3326.corruption_test.zipThe related parts of the schematics and layout look like this: The supply voltage looks good for both unaffected and affected prints. Good: Bad: I've seen TIs document about the flash corruption issue (slaa471), but they mention the MSP430F5510 is unaffected, and the kind of corruption doesn't seem to be the one I'm seeing. I've also not seen anything related in the errata (slaz301j), except "Corrupted flash read when SVM low-side flag is triggered" which doesn't seem to be my issue. The chip revision is C, for both affected and unaffected prints. Any help would be appreciated, I really have no idea what to try anymore. Thanks!
  11. Can anybody tell me what is importance of EEPROM,Flash,Rom memories in tiva c launchpad ??Other is that we can write EEPROM,Flash in tiva c launchpad so what is use of this means we can write where we can use it?
  12. Hello All, I am trying to write data into flash which i need to copy it to the SRAM later. I am doing this in assembly and this is part of the code i am trying to use. I have provided the addresses of the FMD, FMA and FMC registers needed for flash programming and then I am copying those addresses into the registers r8,r9 and r10. My question is how do i now load data values into the addresses pointed by the registers r8,r9 and r10? As you can see, I am clearly wrong somewhere and need assistance!! FMD EQU 0x000000AB FMA EQU 0x000000DC FMC EQU 0x000000FF . . . . . . LDR R8, =FMD LDR R9, =FMA LDR R10,=FMC MOV32 [R8], #0xF0F0F0F0 MOV32 R9, #0x00000000 poll MOV32 R10,#0xA4420001 BNE poll Thanks!! BR, \ksnf3000
  13. -KP-

    Flash write time

    Hi, I'm using the Stellaris Launchpad as part of sequencer/sampler musical instrument that I'm working on right now. I use the internal flash to record and store a couple of short 1-sec clips of audio, sampled at 21kHz - 12 bit. With the FlashProgram() function of the peripheral driver library, I store two words or four samples consecutively, so: record 4 samples - write to flash - record 4 samples - write to flash - etc. The recording happens on a timer interrupt, however the program skips an interrupt every 4 times, exactly when FlashProgram() is doing its thing. So I dove in the FlashProgram() code and adjusted the part where it is waiting, or polling, until the write is complete. This way, I thought, my program could continue running while the flash took its time to get written, 50µs or so. But it still continues skipping while it's writing to flash. Any suggestions to solve this? Or is it just impossible to 'do' anything while flash is being written?
  14. I do have a developer working with me, but he is away for a while, and I have been trying to resolved a flash issue we have been having. I am completely stumped. Any thoughts would be welcomed. All values being stored are integers. Using a 430g2553; I can read flash just fine (we had loaded flash data onto the mcu much much earlier in the development path) - here is an example: int *pflash = ( int *) 0x1000; // pointer into data flash settings.checkPumpTurnedOnDelay = *pflash++; settings.pumpOnTestDelay = *pflash++; settings.longSleepDelay = *pflash++; settings.pressurePumpOn = *pflash++; settings.minimumOperationalPressure = *pflash++; settings.mode_led_sound = *pflash++; // BIT0 = single_mode, BIT1 = led, BIT2 = sound settings.failed = *pflash++; Of course I want to be able to store updated settings into flash...... We had been using a buffer arrangement, but had troubles with that. So I have reverted code back to very basic levels. Firstly: erasing the segment: This should at least work, however it does not erase back to 1's. Each time the program runs it still retrieves the stored values from the load along time ago. void prepareToWrite_Seg (int pointer) { volatile char *Flash_ptr; // Flash pointer FCTL2 = FWKEY + FSSEL0 + FN3+ FN4; // MCLK/16 for Flash Timing Generator Flash_ptr = (char *) pointer; // Initialize Flash pointer FCTL1 = FWKEY + ERASE; // Set Erase bit FCTL3 = FWKEY; // Clear Lock bit *Flash_ptr = 0; // Dummy write to erase Flash segment while((FCTL3 & BUSY)); FCTL3 = FWKEY + LOCK; } Then the operation to write values: #define mFlashWriteEnable {while (FCTL3 & BUSY);FCTL1 = FWKEY;FCTL1 = FWKEY + WRT;} // Set WRT bit for write operation #define mFlashWriteDisable {while (FCTL3 & BUSY);FCTL1 = FWKEY +LOCK;} // disable write operation int *Flash_ptr; prepareToWrite_Seg (0xFC00); Flash_ptr=(int *)0xFC00; mFlashWriteEnable; *Flash_ptr++ = settings.checkPumpTurnedOnDelay; *Flash_ptr++ = settings.pumpOnTestDelay; *Flash_ptr++ = settings.longSleepDelay; *Flash_ptr++ = settings.pressurePumpOn; *Flash_ptr++ = settings.minimumOperationalPressure; *Flash_ptr++ = settings.mode_led_sound; // BIT0 = single_mode, BIT1 = led, BIT2 = sound *Flash_ptr++ = settings.failed; mFlashWriteDisable; .
  15. To know the FLASH and an estimate of the RAM used, find the location of the size utility /Applications/Energia.app/Contents/Resources/Java/hardware/tools/msp430/bin/msp430-size compile a sketch and find the location of the elf file
  • Create New...