USB specs-Request error

#633739
Lesenswert?

Das steht schön in der Spec unter 9.2.7 beschrieben. Ich zitiere mal: 
"When a request is received by a device that is not defined for the 
device, is inappropriate for the current setting of the device, or has 
values that are not compatible with the request, then a Request Error 
exists. The device deals with the Request Error by returning a STALL PID 
in response to the next Data stage transaction or in the Status stage of 
the message. It is preferred that the STALL PID be returned at the next 
Data stage transaction, as this avoids unnecessary bus activity."
Gast #633753
Lesenswert?

The device deals with the Request Error by returning a STALL PID
in response to the next Data stage transaction or in the Status stage of
the message.

Genau auf diese Zeile bezieht sich meine Frage, da ich nach einer STALL 
PID nüx mehr vom HOST höre wollte ich vielleicht was anderes schicken,
>or in the Status stage of the message.
das währ doch |sync|data0|0x0000|EOP
oder???
grüüüße
#633765
Lesenswert?

>> or in the Status stage of the message.
> das währ doch |sync|data0|0x0000|EOP

Nein, da in der Status Stage grundsätzlich DATA1 PID verwendet wird. Du 
sollst im Fehlerfall aber STALLen. Also entweder blockierst Du die 
Daten-Phase oder, falls es keine weiteren Daten gibt, die Status Stage. 
Mehr meint das nicht. DATA0 ist hier absolut fehl am Platz, ein 
irritierter Host wird Dein Device vermutlich resetten und es erneut 
versuchen. Das macht er dann so lange, bis er entnervt aufgibt und Dein 
Device deaktiviert.

Wenn Du nach dem STALL vom Host nichts mehr hörst, hat das eine andere 
Ursache. Je nach SIE könnte es sein, dass Du nach erfolgtem STALL per 
Hand wieder in "betriebsbereit" zurückschalten mußt. Das weiß ich aber 
nicht, da Du darüber keine Informationen herausgegeben habe. Auch sonst 
sind die Infos recht dürftig, daher bleibt nur der Tipp: Schau Dir das 
mit einem Protokoll-Analyzer an.

Antwort schreiben

Bitte melde dich an, um einen Beitrag zu schreiben.

oder

Mit Google-Account einloggen

Die Registrierung ist kostenlos und dauert nur eine Minute.

Jetzt registrieren