Quantcast
Channel: MSP low-power microcontroller forum - Recent Threads
Viewing all 21954 articles
Browse latest View live

CCS/MSP430F2418: MSP430F2418

$
0
0

Part Number: MSP430F2418

Tool/software: Code Composer Studio

how can i change sampling frequency in ADC12 when using pulse sample mode.


MSP-FET: UART fails after power-cycle

$
0
0

Part Number: MSP-FET

I'm testing Spy-Bi-Wire and UART functionality between the MSP-FET and an MSP430FR5969. In order to isolate these components, I've attached jumper wires between the relevant pins on the MSP-FET and the pins that are normally jumper-ed together to connect the ez-FET to the MSP430.

Below is a pinout of the MSP-FET taken from slau647m and a picture of the MSP430FR5969 launchpad:

Spy-Bi-Wire

I've connected the relevant pins (shown in green) and I'm able to program the MSP consistently.

UART

The UART connection is shown in red. After wiring everything up I was able to echo characters with the example code provided. However, after disconnecting the MSP-FET and plugging it back in, I can still program the MSP but the UART is totally unable to send characters to the MSP. I used an o-scope to verify that the MSP-FET isn't sending anything. Closing/opening the serial terminal and CCS do nothing. No amount of power cycling the MSP-FET restores the ability to send characters. The only thing I've found to fix this is a PC reboot.

Is there any way to fix/prevent this?

 

MSP430I2041: How to determine read or write in I2C slave?

$
0
0

Part Number: MSP430I2041

I am writing an I2C slave for the MSP430i2041 and I would like to be able to detect whether the master is writing or reading. I2C dictates that when the master wants to write it sends (address << 1) | 0 and when it wants to read it sends (address << 1) | 1, with the final bit indicating write (0) or read (1).

On the MSP side, how do I detect the read / write bit? I have examined the UCBxADDRX register after receiving UCSTTIFG and it contains only the right justified address. It does not seem to include the read/write bit.

Is there some way to get the read/write bit?

Thanks,

Jason

CCS/MSP430FR5992: Invalid time value in RTC_C module

$
0
0

Part Number: MSP430FR5992

Tool/software: Code Composer Studio

Hi, 

I've a problem with RTC_C module. 

My board does not have an external oscillator. I need to run RTC with only internal oscillators available.
I launched ACLK from the VLO source and MCLK from the DCO source. Unfortunately, the time entered in the time registers does not change.

Which clocks should I run and from which sources to get full functionality without an external oscillator?

Best regards, 

Paulina

Compiler/MSP430FR5994: Default to __data20_* instructions

$
0
0

Part Number: MSP430FR5994

Tool/software: TI C/C++ Compiler

Hi

My team is using a library called Flatbuffers (https://google.github.io/flatbuffers/) to read some of our application data from memory. This library generates code to access memory, which is included as a header. This approach has worked correctly when the data was placed in FRAM, but does not work in FRAM2 since the generated code is built using standard memory accesses. The generated header file is over 10,000 lines long and hard to read so it isn't feasible to change every memory access. Is there a compiler option to default to the __data20_* assembly sequences?

Thank you, Ryan

EVM430-FR6043: GUI Ultarsonic Design Center notices "correlation overrun error"

$
0
0

Part Number: EVM430-FR6043

Hello,

When I use EVM430-FR6043 to do test on my runner equipped with ultrasonic sensors, somehow GUI UDC notices me "correlation overrun error".

Sometimes the measurement carry on correctly,  sometimes not.

Could you explain some limits of "correlation method" in the demo "UltrasonicGasFR6043_02_20_00_12_windows_installer", so I can configure parameters that would avoid this kind of error.

Thank you.

MSP-EXP430F5529LP: Help establishing printf()

$
0
0

Part Number: MSP-EXP430F5529LP

Hi,

 We are trying to use our Launchpad as an interface to our PC for another system and having difficulties. To ask a simple question, how do you get printf() working for the Launchpad? We have tried the following -

Procedure:

  • New CCS Project
  • Add 'printf()' to main()

This is not printing to the CCS or serial consoles, how does this work? We have dove through both references to no avail, is this a simple config adjustment?

MSP430F2417: Unexpected PUC (Resolved)

$
0
0

Part Number: MSP430F2417

Another obscure problem solved: I am sharing this in the hope that it helps somebody.

A new project with a part (F2417) which I have used loads of times before was restarting occasionally with unexpected PUC.  This would occur after running for several tens of seconds, but the run time would vary considerably.

Quoting from SLAU144J (MSP430x2xx Family User's Guide):

"The following events trigger a PUC:

  • A POR signal;
  • Watchdog timer expiration when in watchdog mode;
  • Watchdog time security key violation;
  • Flash Memory security key violation;
  • A CPU instruction fetch from the peripheral address range 0h to 01FFh."

I am using CCS 8.3.1.00004 with the TI-supplied 'boot.c' v4.3.1

I investigated this by setting a breakpoint at the very first instruction in the restart ISR which is the STACK_INIT() macro.  This means that the stack is still intact from the PUC event, as is the SR and interrupt flags.

A POR would leave either the PORIFG or RSTIFG flag set in IFG1.  Neither flag was set.

Either of the watchdog-triggered events would leave WDTIFG set in IFG1.  Again, no flag.

The project does not use the Flash memory controller at all, and in any case the KEYV flag was not set.

The Status Register was clear.

The SP pointed to a location in the assigned stack area, and when the (20-bit) address was assembled, it always pointed to a piece of code which monitors the crystal oscillator XT2, which runs at the maximum specified 16 MHz when the SVS indicates a Vcc of 3.3V or more.  As part of this code, BCSCTL3 was refreshed with the appropriate configuration, and it was the write to BCSCTL3 which had just been executed immediately before each PUC.

Now the code tests the value in BCSCTL3 and only writes to it if necessary.  Result: no unexpected PUC events.

Ray


CCS/MSP430FR6043: Get firmware address start/end, excluding persistent variables?

$
0
0

Part Number: MSP430FR6043

Tool/software: Code Composer Studio

Hi

I need to calculate a CRC checksum on the firmware version on a MSP430 which should stay constant until a firmware update(for security means). I know the FRAM start and end addresses, but the problem is that I have persistent variables in FRAM that is changing during runtime, which would affect the CRC result. 

Is there a way to find the start/end addresses of the firmware and excluding the persistent variables? (without manually checking memory as it would change when the code changes).

Thanks in advance 

MSP430FR2476: Help finding beginning of program in memory

$
0
0

Part Number: MSP430FR2476

Hello,

In reading the datasheet the memory address for the beginning of code (program) space is 0x8000 to 0xFFFF.  When I look at my assembly in code composer it actually starts at 0x882A as shown in the attached screenshot.  I'm thinking this is define by the linker?

The reason I'm looking into this is because I need to send the MSP an updated image/bit file via the BSL and I need to figure out where exactly to put it. 

Questions

1. Can I just use the address shown in the debugger - 0x882A and the MSP will be happy?

2. Why is the program code not at 0x8000?

 

RSLK LAB 3 SOLUTION CODE

$
0
0

Hello,

Does anyone have the solution code to Lab 3 for the RSLK? It is writing an assembly code to convert sensor data into mm.

Thanks.

MSP-TS430RGZ48B: MSP low-power microcontroller forum

$
0
0

Part Number: MSP-TS430RGZ48B

Hello Team,

my customer want to got the MSP-TS430RGZ48B original PCB layout file, no PDF version, can you let me know whether can find it? thanks..

MSP-EXP432P4111: oad SAP succeeds but oad SNP fails

$
0
0

Part Number: MSP-EXP432P4111

Hi, I use the MSP-EXP432P4111 Launchpad. First neither the SAP and SNP OAD updates failed both! I managed to solve the first one so OAD SAP functions fine. The cause of the problem was that the 'erase' function took to long so, I split it up in four smaller steps wich solved the problem. But I don't yet manage to solve the SNP OAD failure. So I checked:

- downloading from android phone the crc32 using an added crc32 software function I added to countercheck the used ROM CRC32 function. Result OK!

- then I checked the transmission steam from MSP -> CC2640R2. Result OK!

- then I compared the original content of the used space in memory with the uploaded(OAD) version after that was 'programmed into the cc2640r2'.

 For this I made a memory dump from both the original and the BSL new one(which is equal to the original)

Resulting in exactly the same memory except for:

address 0x128c ti_sysbios_knl_Task_inistackFlag__C
data 0xFF000001 ipv 0x00010001

address 0x1300 xdc_runtime_Error_policy__C
data 0xFFFFFF00 ipv 0x00000001

address 0x1366c
data 0xFFFFFFFF ipv 0x00000000

address 0x1e000
data 0x00100000 ipv 0x000000FF

address 0x1e004
data 0xFFFFFFFF ipv 0x00000000

Using Saleae logic pod I also noted that the PUI never comes!

I use as SNP: simple_np_cc2640r2_app for the snp (XDCtools:3.51.3.28_core, Simplelink CC2640R2 SDK 3.30.0.20, compiler: TIv18.1.4.LTS)

I use as SAP: oad_firmware_update_MSP_EXP432P4111_tirtos_ccs for the sap ( XDCtools:3.51.03.28_core, SimpleLink MSP432P4 SDK 3.20.06, COMPILER:  TIv18.1.4.LTS)         

Here picture of capture, PUI should appear on Rx_SAP:

Please advise,

regards, Laurent

2M Engineering, the Netherlands

CCS/MSP430FR6043: Matching the Hardware CRC32 method and linker CRC32_PRIME

$
0
0

Part Number: MSP430FR6043

Tool/software: Code Composer Studio

Hi!

What are the required way of calculating the CRC in the same way as the linker CRC32 (CRC32_PRIME) with the hardware CRC32 module? 

crc_table(linkerCRC, algorithm=CRC32_PRIME)

E.g.set data in reversed? get result in reversed? XOR with what? seed with what etc? 

CRC32_setSeed(0x00000000, CRC32_MODE);
uint32_t *FRAM_memory=(uint32_t*)linkerCRC.recs[0].addr;
for(i=0; i<(linkerCRC.recs[0].size); i+=4){
CRC32_set32BitData(*FRAM_memory++);
}
result=(CRC32_getResult(CRC32_MODE));

The above is my test code that doesn't match the linker's result.

Thanks in advance

CCS/TIDM-BPM: TIDM-BPM pump and valve duty cycles

$
0
0

Part Number: TIDM-BPM

Tool/software: Code Composer Studio

Hello,

I am interested in the TIDM-BPM device for blood pressure monitoring and I checked out the source code provided on the webiste. I was especially checking the pwm signals for the pump and valve. Here is the part of the code concerned : 

void timer0Init(void)
{
P1DIR|=BIT2+BIT3;
P1SEL|=BIT2+BIT3; //SELECT P1.2/P1.3 AS TA0 OUTPUT

TA0CCR0 = 4000; //
TA0CCTL1 = OUTMOD_7; // CCR1 toggle/set,PUMP
TA0CCTL2 = OUTMOD_1; //VALVE
TA0CCR2 = 3400; // CCR1 PWM duty cycle for valve
TA0CCR1 = HIGH_AIRIN; // for pump with HIGH_AIRIN = 2500
TA0CTL = TASSEL_2 + TACLR+ MC_1; // SMCLK, up mode,
}

My question is about the duty cycle of these two pwm signals. How the duty cycle of these pwm signals was determined compared to the inflation and deflation speed ? In other words what's the relationship used between the duty cycle and the inflation speed (for pump) and deflation speed (for valve). I mean let's say we want to reach a certain pressure of 200 mmHg in 20 s. How should we determine the duty cycle of the pump to reach this pressure in 20s ? I hope that my question is clear.

Thank you very much.

Best regards,

Mike


MSP430FR5994: Max DVSS current?

$
0
0

Part Number: MSP430FR5994

What is the Absolute Maximum Rating for mA through DVSS ?

CCS/MSP430FR5969: How to obtain a map of all the allocated memory addresses

$
0
0

Part Number: MSP430FR5969

Tool/software: Code Composer Studio

I have measured the power consumption of an MSP430FR5969 while writing
to FRAM with TI's example code and the power consumed while writing to
its SRAM with a variation of TI's example code. Essentially it
consists of a declaration and a write function as shown below.

FRAM declaration (__TI_COMPILER_VERSION__ is defined)

#pragma PERSISTENT(FRAM_write)
unsigned long FRAM_write[WRITE_SIZE] = {0};


FRAM write function

void FRAMWrite(void)
{
  unsigned int i=0;

  for ( i= 0; i< WRITE_SIZE; i++)
  {
    FRAM_write[i] = data;
  }
}


SRAM declaration (__TI_COMPILER_VERSION__ is defined)

#pragma DATA_SECTION(SRAM_write, ".sram")
unsigned long SRAM_write[WRITE_SIZE] = {0}

SRAM write function

void SRAMWrite(void)
{
  unsigned int i=0;

  for ( i= 0; i< WRITE_SIZE; i++)
  {
    SRAM_write[i] = data;
  }
}

Now I have been asked for a "memory trace". Essentially I need to
figure out how much memory is being occupied and which memory
locations have been allocated.

The code clearly treats the memory as a single contiguous address
space, but I don't know if this is how the addresses are actually
being allocated (due to compilers, paging etc). Is there any tool that
I can use in order to obtain a memory map in which the allocated
regions are highlighted?

Thanks in advance,
Chandran

MSP430F5659: Firmware Upgrade Corruption Issue

$
0
0

Part Number: MSP430F5659

 Hi TI team,

Our Current Procedure for uploading firmware:

We connect the board with PC using USB interface cable. We put the MSP430F5659 board into boot mode.  Then we upload the firmware using the "Python firmware upgrade tool".

During uploading time if some Disturbance/Disconnection happened in the USB I/F cable. Firmware on the board erased. Then no firmware exists on the board and it is in the boot mode after the power cycle.

Our Issue:

When the firmware is erased as mentioned in the above case,  Again we try to reupload the firmware using the "Python firmware upgrade tool".

But sometimes in python firmware upgrader "READY" symbol not appears, So we cannot upload the firmware using a normal method instead we used the "FET Emulation Tool" with JTAG connector.

This is not a user-friendly method for the customer.

 

Our Requirement:

So to avoid this, We looking for a solution like this.

If any firmware erases during upload due to user mishandling, The board should automatically revert back to previous firmware without any user intervention.

 

Example:  If the board is having firmware 1.0 and user trying to upload 2.0, Due to some reason while uploading  2.0 some disturbance/disconnection happened in USB I/F cable.

In this case, if the board is restarted then it should have firmware 1.0.

 

Kindly advise on this requirement on high priority.

 

Thanks and Regards

Manoj

 

 

 

 

 

CCS/MSP430FR6820: MSP430FR6820: FRAM variable definition

$
0
0

Part Number: MSP430FR6820

Tool/software: Code Composer Studio

I can create and use a FRAM variable. It is not difficult. But I need to
create a variable (an array of bytes about 1kB) with a constant address.
The address must be the same even if we modify the program code. I
suppose it is not a good solution to define only a variable with an constant
address in FRAM like char *myFRAMvariable = 0x08000 because somewhere of
the occupied place could be start of program code. I expect I need to also
modify the .cmd file to create a new section for  FRAM variables and
decrease the section of program code. But I do not know how to do it.

Thank you in advance for your reply.

MSP430AFE252: inquiry about Approximity sensor design via captivate center for temperature drift test

$
0
0

Part Number: MSP430AFE252

Hello,

I use the silicon to do Approximity sensor design on my own board via CapTIvate center(studio), I need to test the raw count data from 20 C to 50C and I set LTA filter to 7(highest step) to compensate the temperature drift, I just do calibration once after communication successfully between PC and my board, then I find that the delta value(for approximity judgement) decrease dramatically during the heating and cooling procedure and it's hard to distinguish the real trigger for approximity with highest temperature such as 50C. I haven't expected that delta value is so sensitive to temperature change.I'd like to know if I need to do the calibration by pressing calibration button on the studio from time to time for fixing this issue or is there any other method to make sensor not so sensetive to temperature?Thanks!

B.R

YUKE

Viewing all 21954 articles
Browse latest View live