Quantcast
Channel: Forums - Recent Threads
Viewing all 262198 articles
Browse latest View live

CC3200-LAUNCHXL: MQTT Client + TLS/SSL + AWS IoT

$
0
0

Part Number:CC3200-LAUNCHXL

Hello,

I'm trying to connect to AWS IoT using MQTT Client example of SDK 1.3 with a CC3200, but it's not working.

Here is the output on my serial terminal:

This is what i have going till date:

  1. On the AWS IoT side, I created a "thing", a policy to access that thing, linked it to one another and generated the certificates.
  2. I made the conversion of the three .PEM certificates to .DER using OpenSSL.
  3. To test whether the certificates and settings in AWS were correct, I tried to post a data in AWS using MQTT.fx. This worked normally and I was able to publish the data.
  4. From that point, I returned to the CC3200 and began to customize the "MQTT Client Exemple" according to the needs of AWS IoT:
    #define MQTT_3_1_1              true
    #define MQTT_3_1                false
    #define WILL_QOS                QOS0
    #define SERVER_ADDRESS          "a2ofr87029z36p.iot.us-east-2.amazonaws.com"
    #define PORT_NUMBER             8883
    #define SERVER_MODE             MQTT_3_1_1
    #define PUB_TOPIC_FOR_SW3       "myTopic1"
    #define PUB_TOPIC_FOR_SW2       "myTopic2"
    
    #define SL_SSL_KEY_CERT         "/cert/private.der"
    #define SL_SSL_CLIENT_CERT      "/cert/client.der"
    #define SL_SSL_CA_CERT          "/cert/ca.der"
    
    #define DAY     10
    #define MONTH   5
    #define YEAR    2018
    #define HOUR    16
    #define MINUTE  0
    #define SECOND  0
    
    char *security_file_list[4] = {
        SL_SSL_KEY_CERT,
        SL_SSL_CLIENT_CERT,
        SL_SSL_CA_CERT,
        NULL
    };
    
    connect_config usr_connect_config[] =
    {
        {
           {
               #ifdef USE_SSL
               {
                    SL_MQTT_NETCONN_SEC | SL_MQTT_NETCONN_URL,
                    SERVER_ADDRESS,
                    PORT_NUMBER,
                    SL_SO_SEC_METHOD_TLSV1_2,
                    0xFF,
                    4,
                    security_file_list
               },
               #else
               {
                    SL_MQTT_NETCONN_URL,
                    SERVER_ADDRESS,
                    PORT_NUMBER, 0, 0, 0,
                    NULL
               },
               #endif
               SERVER_MODE,
               true,
            },
            NULL,
            "user1",
            NULL,
            NULL,
            true,
            KEEP_ALIVE_TIMER,
            {Mqtt_Recv, sl_MqttEvt, sl_MqttDisconnect},
            TOPIC_COUNT,
            {TOPIC1, TOPIC2, TOPIC3},
            {QOS0, QOS0, QOS0},
            {WILL_TOPIC,WILL_MSG,WILL_QOS,WILL_RETAIN},
            false
         }
    };
    
    SlDateTime_t g_time;
        g_time.sl_tm_day  = DAY;
        g_time.sl_tm_mon  = MONTH;
        g_time.sl_tm_year = YEAR;
        g_time.sl_tm_sec  = SECOND;
        g_time.sl_tm_hour = HOUR;
        g_time.sl_tm_min  = MINUTE;
        sl_DevSet(SL_DEVICE_GENERAL_CONFIGURATION, SL_DEVICE_GENERAL_CONFIGURATION_DATE_TIME, sizeof(SlDateTime_t), (unsigned char *)(&g_time));
    
        SlDateTime_t dateTime = {0};
        _u8 configLen = sizeof(SlDateTime_t);
        _u8 configOpt = SL_DEVICE_GENERAL_CONFIGURATION_DATE_TIME;
        sl_DevGet(SL_DEVICE_GENERAL_CONFIGURATION,&configOpt, &configLen,(_u8 *)(&dateTime));
    
        UART_PRINT("******************************************************\n\r");
        UART_PRINT("Day %d, Mon %d,Year %d, Hour %d, Min %d, Sec %d\n",dateTime.sl_tm_day,dateTime.sl_tm_mon, dateTime.sl_tm_year, dateTime.sl_tm_hour, dateTime.sl_tm_min, dateTime.sl_tm_sec);
        UART_PRINT("******************************************************\n\r");
    
        //
        // Initialze MQTT client lib
        //
        lRetVal = sl_ExtLib_MqttClientInit(&Mqtt_Client);


5. And then I flashed all the certificates using UniFlash:

After all the above steps, I still can not connect to the Broker.

Someone, please, have any suggestions?

Tiago Silva.


LDC1000: Minimizing the impact of distance on Rp

$
0
0

Part Number:LDC1000

Hi,

Background information: I would like to determine the composition of a particular metal+non-metal material. Due to chemistry I do not fully understand, when a block of it is cast, more non-metals at the top than at the bottom. The change in composition will have a significant and measurable impact on the resistivity according to literature I've read and some preliminary tests.

My setup: I have a coil facing down at a fixed height. Below it, I have the block on a motorized platform. I have laid the block on its side, such that the variation in composition, and thereby in resistivity, is now on the x axis. As the platform moves left or right, I am able to observe a change in Rp.

My problem: I believe in order for this to work with any accuracy, the distance between the block and the coil has to be uniform. As the blocks are not perfectly flat, there can be up to 1.5mm of variation in the distance between the block and the coil.

My question: What steps, if any, can I take to minimize the effect of the change in distance on the Rp value? 

Note: I do not care for the value of Rp in absolute terms, only in its variation along the block.

In order to determine the relative composition of the block along its height, I have turned it on its side and put it on a motorized platform. The inductor coil is at a fixed height above the platform. which will move at a constant speed from left to right, thereby creating a line trace of the resistivity variations from bottom to the top of the block.

I would like to use the LDC1000 to detect certain impurities in blocks of metal. Due to the way the 

This should be possible according to the literature I've read and some preliminary tests when the distance is fixed.

The blocks will be on a motorised platform, which will move at a constant speed from left to right.

resistivity of the brick whilst moving at a constant speed from left to right, thereby creating a line trace of the resistivity variations from bottom to the top of the block.

TPA3116D2: BTL vs PBTL Loads

$
0
0

Part Number:TPA3116D2

The TI  page for TPA3116 says this:

"The TPA31xxD2 series are stereo efficient, digital amplifier power stage for driving speakers up to 100 W / 2 Ω in mono."

Does this mean TPA3116 can safely run a 2ohm load in PBTL mode if proper cooling is in the application?

But later down on the TI page it says "Load (min)(ohms) 4", so does this mean BTL mode?

The 2ohm statement seems odd because the specs advertise 2x50w(4ohm), which is essentially 100w 4ohm.

The TI page I speak of is TI dot com /product/TPA3116D2

Can you please clarify.

CC1310: programming interface on a custom board

$
0
0

Part Number:CC1310

Hi, 

I am an analog/RF designer and am totally new to the ARM and embedded design world so pardon my stupid questions. I am trying to use this part in a custom board and will still be able to use the Code Composer for programming.

Here is my question: is the cJTAG the programming interface between a PC and the CC1310? If so, is there an USB adapter that I can buy for programming?

Thanks 

TPA3116D2: TPA3116 Power Ratings

$
0
0

Part Number:TPA3116D2

On your page TI dot com /product/TPA3116D2

Are the watt (W) ratings RMS or something other?

I ask because the Output power line just says "Output Power(W) 50"

  1. Is this "W" RMS? If it's RMS then why does the PBTL line state "W(max) 100"?
  2. The TPA3116 has 4 amps in it, 2x two BTL's, or stereo output, so is one TPA3116 a 2x50 package?

CCS/66AK2H12: Cannot run multiple distinct .out executables via Multi-Processor Manager (MPM) Command Line utility.

$
0
0

Part Number:66AK2H12

Tool/software: Code Composer Studio

Hi all, I've got a problem that's kept me scratching my head for the last week.

I'm trying to run a different .out executable on each DSP core of my Keystone II via the Multi-Processor Manager Command Line, but only one of those loaded .out executables will actually run.

This is the sequence of commands I'm entering into the command line:

mpmcl reset dsp0

mpmcl reset dsp1

(repeat for DSP cores 2 - 7...)

mpmcl status dsp0

mpmcl status dsp1

(repeat for DSP cores 2 - 7...)

mpmcl load dsp0 prog_a.out

mpmcl load dsp1 prog_b.out

(repeat for DSP cores 2 - 7, loading prog_c.out, prog_d.out, and so on...)

mpmcl run dsp0

mpmcl run dsp1

(repeat for DSP cores 2 - 7...)

mpmcl reset, mpmcl status, mpmcl load, and mpmcl run all return success messages after being called. However, only one of the loaded DSP cores will actually run - which core runs is entirely

random.

It should be noted that I have tried the same procedure using .out files compiled from TI's provided sample test code and all cores were able to run simultaneously, yet I have no luck with my own .out executables.

Furthermore, If load up and run just one DSP core, I can run each of my own .out executables with no problem - they just can't run simultaneously! I'm compiling these programs with Code Composer Studio 6.1.2.

Anyone have any ideas?

does this exist?

$
0
0

It would be nice to get a power bank with built-in wall plug (110~240V), built-in USB type C cable +/- C-to-lightning and C-to-microUSB adapters and a USB QC3.0 output port! Is anything like that available now or in the works? 

Availability of these features in power banks volume options, eg a slimmer (7-10mm thick) 5000MAh and a 10-13mm thick 10000MAh varieties that would be even more desirable. 
Future developments?
I would be grateful for your comments, info.
Marina 

TDC7201-ZAX-EVM: Looking for a Rasberry Pi version of tdc7201-zax-evm program

$
0
0

Part Number:TDC7201-ZAX-EVM

I have been working on creating a lidar device using the tdc7201 but i need a way to connect it to a raspberry pi. Does anyone have a wiring diagram or a Raspberry pi code I could use.


CCS/MSP430FR5994: How to use ADC to measure voltage

$
0
0

Part Number:MSP430FR5994

Tool/software: Code Composer Studio

Here is a code that was in the FRAM utilities example that uses ADC to detect when power is lost

How do I modify this code to detect when the device drops down to a certain voltage

void initAdcMonitor(void)
{
    /* Initialize timer for ADC trigger. */
    TA0CCR0 = (SMCLK_FREQUENCY/ADC_MONITOR_FREQUENCY);
    TA0CCR1 = TA0CCR0/2;
    TA0CCTL1 = OUTMOD_3;
    TA0CTL = TASSEL__SMCLK | MC__UP;

    /* Configure internal 2.0V reference. */
    while(REFCTL0 & REFGENBUSY);
    REFCTL0 |= REFVSEL_1 | REFON;
    while(!(REFCTL0 & REFGENRDY));

    /*
     * Initialize ADC12_B window comparator using the battery monitor.
     * The monitor will first enable the high side to the monitor voltage plus
     * 0.1v to make sure the voltage is sufficiently above the threshold. When
     * the high side is triggered the interrupt service routine will switch to
     * the low side and wait for the voltage to drop below the threshold. When
     * the voltage drops below the threshold voltage the device will invoke the
     * compute through power loss shutdown function to save the application
     * state and enter complete device shutdown.
     */
    ADC12CTL0 = ADC12SHT0_2 | ADC12ON;
    ADC12CTL1 = ADC12SHS_1 | ADC12SSEL_0 | ADC12CONSEQ_2 | ADC12SHP;
    ADC12CTL3 = ADC12BATMAP;
    ADC12MCTL0 = ADC12INCH_31 | ADC12VRSEL_1 | ADC12WINC;
    ADC12HI = (uint16_t)(4096*((ADC_MONITOR_THRESHOLD+0.1)/2)/(2.0));
    ADC12LO = (uint16_t)(4096*(ADC_MONITOR_THRESHOLD/2)/(2.0));
    ADC12IFGR2 &= ~(ADC12HIIFG | ADC12LOIFG);
    ADC12IER2 = ADC12HIIE;
    ADC12CTL0 |= ADC12ENC;
}

#pragma vector = ADC12_VECTOR
__interrupt void ADC12_ISR(void)
{
    switch(__even_in_range(ADC12IV, ADC12IV_ADC12LOIFG)) {
        case ADC12IV_NONE:        break;        // Vector  0: No interrupt
        case ADC12IV_ADC12OVIFG:  break;        // Vector  2: ADC12MEMx Overflow
        case ADC12IV_ADC12TOVIFG: break;        // Vector  4: Conversion time overflow
        case ADC12IV_ADC12HIIFG:                // Vector  6: Window comparator high side
            /* Disable the high side and enable the low side interrupt. */
            ADC12IER2 &= ~ADC12HIIE;
            ADC12IER2 |= ADC12LOIE;
            ADC12IFGR2 &= ~ADC12LOIFG;
            break;
        case ADC12IV_ADC12LOIFG:                // Vector  8: Window comparator low side
            /* Enter device shutdown with 64ms timeout. */
            ctpl_enterShutdown(CTPL_SHUTDOWN_TIMEOUT_64_MS);

            /* Disable the low side and enable the high side interrupt. */
            ADC12IER2 &= ~ADC12LOIE;
            ADC12IER2 |= ADC12HIIE;
            ADC12IFGR2 &= ~ADC12HIIFG;
            break;
        default: break;
    }
}

TLV320ADC3101: sound measure consult

$
0
0

Part Number:TLV320ADC3101

Hi all, one of my customer wants to measure their sound and use it to control the brightness of LED. For I am a freshman in this area, can you recommend some solutions for me to understand how we can do so? Or do you know some TI parts that can measure the sound and convert it to digital or analog quantity that can be read by MCU. Thank you very much!

CCS/LAUNCHXL-F28379D: Level Shifting for PWM and GPIO

$
0
0

Part Number:LAUNCHXL-F28379D

Tool/software: Code Composer Studio

Hello!

I am currently working with a Teknic ClearPath motor that has an integrated servo drive, which applies torque proportional to a PWM duty cycle as supplied using a microcontroller (the F28379D in this case). The motor drive requires the PWM signal and other inputs to be 5V, whereas the F28379D GPIO pins provide 3.3V. The motor drive also requires a "motor enable" signal and the "motor direction" signal, which are digital high or low. I am currently using the SparkFun bidirectional level shifter to convert the 3.3V signal from ePWM1A and GPIO 2 and 3 of the microcontroller to 5V which is then fed into the motor drive. In the F28379D datasheet, I see that the LaunchPad has an in-built level shifter, which connects GPIO 20, 21, 99, 54, 55, 57 to EQEP pins. I would like to know if I can use these pins to provide the signals to the motor instead of using an external logic level shifter. If it is possible to use the in-built level shifter, I would like to know which specific pins to configure, and how exactly to configure them. Thank you.

Regards,

Samvrit

TINA/Spice/THS4121: DC bias solution shows VDD values different from those assigned, based upon Vocm value.

$
0
0

Part Number:THS4121

Tool/software:TINA-TI or Spice Models

I've been working with the THS4121 SPICE model and noticed that the DC bias solution shows VDD (pin 3) values different from those assigned at the Vdc source. The value varies based upon the DC level provided to Vocm (pin2). Seemingly, this should not be the case. For example, If I supply VDD with 3.3V and Vocm with 0.6V, through a 100 ohm resistor, the DC bias solution on the VDD pin is 1.333V. If I increase the voltage on Vocm from 0.6V to 1.2V, the VDD pin bias solution shows 2.545V. The DC bias solution on the Vocm pin correctly shows the voltage value being supplied.

According to the spec, the Vocm pin is internally biased to VDD/2. Regardless, applying a voltage on the Vocm pin should not impact the VDD pin. Tying Vocm to ground through a resistor has similar bad effects. Removing the Vdc source from the VDD pin, the DC bias solution still shows an odd VDD pin voltage value.

What am I missing?

MSP430F5335: cannot use MSP430flasher with '/dev/ttyS9'

$
0
0

Part Number:MSP430F5335

I am using Windows WSL for development and I am trying to use MSP430Flasher but the tty file name is "/dev/ttyS0".  Any way to use the Flasher with a tty without name pattern ttyACMx?

AM5748: package height

LAUNCHXL-CC1350: How to perform BLE OAD?

$
0
0

Part Number:LAUNCHXL-CC1350

Greetings,

I am trying to use OAD to download my application image on CC1350 using bluetooth. There are so many documents and web pages that mentioned OAD and now I have many questions about how to do it.

1) Where exactly is the piece of code that performs the BLE OAD operation? (the code on CC1350 that receives the new image and flash it)

2) The demo in the launchpad welcome page (here) talks about downloading the binary file using a mobile app. But the BLE-Stack user guide (here) talks about downloading the binary file using another launchpad "OAD Downloader". What is the difference? and which one I can implement in my application? Is there a code for both of them in the examples? 

3) What is the memory mapping of CC1350 OAD target? I need to know what modules exist in the memory and the size of each, and how much left for my application.

4) In the out of box demo [using mobile app], how can it switch back from the flashed application to the original firmware?

5) I am not getting how things works inside the OAD target system. Is there two applications, one for OAD and one for main application? and it shouldn't exit from the OAD application until it gets a new image? ( I find this strange if true). Another understanding is that it doesn't enter the OAD application unless there is a variable set in the last iteration of the main application on the MCU. Which one is right? and if both wrong then what is the correct scenario for this?

6) Is there a clear document/source that explains the sequence of OAD operation and the hierarchy of the OAD target system?

Thanks in advance.

* James *


SN75LVCP601: Use as USB3.0 Redriver

$
0
0

Part Number:SN75LVCP601

Hi Team,

Is there any objection or pitfalls in using the SN75LVCP601 as an alternative to the TUSB522P to redrive USB3.0 signals? Reason I ask is that customer is already using the SN75LVCP601 for it's intended purpose and would like to try and make it work for USB too.

Looking over the two datasheets, both appear to be super similar even though they comply to two different standards. What makes me think this might work is that the OOB threshold on the SN75LVCP601 is 150mVpp and the LFPS threshold on the TUSB522 ranges from 100mV to 300mV. Seems to be in the same ballpark. Could it work?

Any clarity of help you can provide would be awesome!

Thanks,
Mitchell

Compiler/TM4C129XNCZAD: how to reference section name is C code?

$
0
0

Part Number:TM4C129XNCZAD

Tool/software: TI C/C++ Compiler

Is there a way to programmatically obtain the addresses of the different sections? For example, in my code I want to assign a pointer to the start of the heap, which is in the .sysmem section. Is there some global symbol that I can reference? In the .map file I saw a symbol called _sys_memory, but the compiler generates an error when I try to use it.

Also, the compiler manual says that the linker generates a global symbol called __SYSMEM_SIZE, which is supposed to be the size of the section. It's in the .map file, but I also get a compiler error when I try to use it.

Regards,

Dave

CCS/F28M35H52C: SD Card Write Crashes on Concerto using TI Example

$
0
0

Part Number:F28M35H52C

Tool/software: Code Composer Studio

I have made the sd_card_m3 example using FatFs vn0.04b work properly on my controlCard-based hardware (although the SD card is running on SSI2 instead of SSI0) and the SD functions in that code ll work properly; I can debug this project and the UI signals on UART0 continue to work properly.

I also have a separate CPS_DSTR_m3 project that works with a sister project for the C28 core, this pair have shared memory defined where the C28 writes values to the S0-S7 RAM and the m3 reads it.  I tired to add the SD card functionality from the sd_card_m3 example project to the CPS_DSTR_m3 project but it doesn't work - crashes when I try to run function "ls".  I tried to debug this project but the UI over UART0 stops working when I debug.

There's something odd going on that may be similar to the issue described by Grant E Pitel in this post Grant E Pitel says "The interrupt handler for uartstudio is conflicting with something (probably the SSI), which was causing code to enter a FaultISR.  I worked around the problem by disabling everything related to UART debugging."

How do I disable  "everything related to UART debugging" so that I can see if my issue is the same as he suggested?

I'm really stuck here because my code doesn't work and I can't debug it to find out why. 

CCS/CC3220SF-LAUNCHXL: Problem changing the number of topics to susbscribe in mqtt demo

$
0
0

Part Number:CC3220SF-LAUNCHXL

Tool/software: Code Composer Studio

Hi,

I am working with the mqtt demo and I wanted to change the number of topics I subscribe to. I guess that this are the parameters I have to change

It compiles but when I flash it the board goes crazy and displays an error. On board client disconnected, Subscription error

I will really appreciate help.

Thanks,

Raimundo

UCD90160A: PMBUS_CNTRL at POR

$
0
0

Part Number:UCD90160A

If a rail’s On/Off config is set to CONTROL Pin Only, and the PMBUS_CNTRL pin is active when the UCD90160A comes out of Power On Reset (POR), will the enable for the rail be asserted as soon as any other sequence on dependencies associated with the rail are met?

Or is it necessary to make sure the PMBUS_CNTRL pin sees a rising edge (assuming active Hi Polarity) after a POR for the rail enable to be asserted?

Thanks, -John

Viewing all 262198 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>