Forum Rule: Always post complete source code & details to reproduce any issue!
Page 2 of 2 FirstFirst 1 2
Results 26 to 32 of 32

Thread: When will Teensy marry ESP32?

  1. #26
    Senior Member
    Join Date
    Aug 2017
    Posts
    139
    Quote Originally Posted by vjmuzik View Post
    So I've got all the endpoints working, and it is sending and receiving ethernet packets. I haven't setup a way to change the mac address from what's already stored in the chip, but it is possible and I will work out a way to do that later on. But so far this is certainly promising, as long as it's faster than using a SPI ethernet device I'll be happy and it'll be worth it. Besides from anything complicated because of the lack of a tcp/ip stack it at least sends and receives raw frames. Most of what you see in the serial monitor is from broadcast messages because I have the filter set on the ASIX to allow them through and I believe multicast messages are not currently allowed through besides the one specified for all since the filter on the ASIX is not currently setup for any specific ones to flow through.
    Attachment 17655
    @vjmuzik - Good job with this. I took a break from working with my old USB2LAN adapter to spend the day checking out some of my wireless adapters. They all seem to be using versions of the Reltek WIFI chips. RTL81XXXX style. I spent a lot of time searching the Internet for generic driver source code, datasheets, programming reference manuals with no luck. The closet sources for information is with Linux kernel source code downloaded from GitHub. This stuff is heavily intertwined with the Linux kernel. The most common wireless Reltek chip version used seems to be the RTL8192CU chip. This is used by my CIsco and wifiN usb WIFI dongles. I have a Ralink wireless dongle that uses the RTL2800 chip.
    So for me this may be out of my time available programming (playing) skill level.

    @Forum - Has anybody else done any work with generic RTL8192CU drivers?

    Going back to USB2LAN for now

  2. #27
    Senior Member vjmuzik's Avatar
    Join Date
    Apr 2017
    Location
    Florida
    Posts
    398
    Yeah I looked at the Linux source code for the ASIX driver and couldn’t make much sense of it myself. In my case I was able to find a manual for my chip that describes most of what you need to do, at least what commands are available to use. Then I used Wireshark with the adapter connected to my laptop to see what USB packets were being sent to the device to get it initialized and I cross referenced all of them back to the manual to understand what was happening. Then I recreated the packets in my Teensy driver and it seems to work well enough, I’m still trying to either find a TCP/IP stack to integrate or write my own because I don’t understand how to interface one of the existing ones into something usable.

  3. #28
    Senior Member
    Join Date
    Aug 2017
    Posts
    139
    Quote Originally Posted by vjmuzik View Post
    Yeah I looked at the Linux source code for the ASIX driver and couldn’t make much sense of it myself. In my case I was able to find a manual for my chip that describes most of what you need to do, at least what commands are available to use. Then I used Wireshark with the adapter connected to my laptop to see what USB packets were being sent to the device to get it initialized and I cross referenced all of them back to the manual to understand what was happening. Then I recreated the packets in my Teensy driver and it seems to work well enough, I’m still trying to either find a TCP/IP stack to integrate or write my own because I don’t understand how to interface one of the existing ones into something usable.
    @vjmuzik - A little more progress today. Going through the AN8515 driver for Linux I was trying to find where the driver initializes the adapter. There is is a probe function that basically gathers information about the chip and fills in several Linux net data structures based on that information. Then it calls several more functions in the driver that properly initialize the the adapter. I have been writing my own functions to duplicate this and have got the PHY initialized. The little red activity light is blinking and showing activity. Using Wireshark I am seeing TX activity to it. But obviously not from it.
    This is going to be a step by step process. Hopefully you are making progress to. I only have the old AN8515 based Ethernet dongle right now but I want to order the one you are using on payday.

  4. #29
    Senior Member+ defragster's Avatar
    Join Date
    Feb 2015
    Posts
    9,948
    Quote Originally Posted by wwatson View Post
    @vjmuzik - A little more progress today. Going through the AN8515 driver for Linux I was trying to find where the driver initializes the adapter. There is is a probe function that basically gathers information about the chip and fills in several Linux net data structures based on that information. Then it calls several more functions in the driver that properly initialize the the adapter. I have been writing my own functions to duplicate this and have got the PHY initialized. The little red activity light is blinking and showing activity. Using Wireshark I am seeing TX activity to it. But obviously not from it.
    This is going to be a step by step process. Hopefully you are making progress to. I only have the old AN8515 based Ethernet dongle right now but I want to order the one you are using on payday.
    Sounds like progress. This effort seems deserving of its own thread so as to not get lost on this one …

  5. #30
    Senior Member
    Join Date
    Aug 2017
    Posts
    139
    Quote Originally Posted by defragster View Post
    Sounds like progress. This effort seems deserving of its own thread so as to not get lost on this one …
    @defragster - It's a learning curve for sure and it will take time. You are right. Once I have something substantial to contribute I will start a new thread. Or maybe @vjmuzik will. Going through the Linux driver for the ASIX driver for Linux I noticed that it is using newer methods for access and control than the AN8515. Different author.

  6. #31
    Senior Member vjmuzik's Avatar
    Join Date
    Apr 2017
    Location
    Florida
    Posts
    398
    Indeed I just made a new thread and uploaded my current code to GitHub so you can take a look at that and see if it helps any, it honestly needs a ton of work to get it where I believe it needs to be, but at least the ball is rolling.

  7. #32
    Senior Member
    Join Date
    Aug 2017
    Posts
    139
    Quote Originally Posted by vjmuzik View Post
    Indeed I just made a new thread and uploaded my current code to GitHub so you can take a look at that and see if it helps any, it honestly needs a ton of work to get it where I believe it needs to be, but at least the ball is rolling.
    @vjmuzik -This is great Once I get the same dongle you have I will try to contribute as much as I can.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •